projects
/
gtk4.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3db60ba
)
GtkDialog: Warn about lack of transient parents
author
Matthias Clasen
<mclasen@redhat.com>
Fri, 2 May 2014 22:23:58 +0000
(18:23 -0400)
committer
Matthias Clasen
<mclasen@redhat.com>
Fri, 2 May 2014 22:23:58 +0000
(18:23 -0400)
We want make it mandatory for dialogs to have transient parents,
eventually. This is a first step in that direction.
gtk/gtkdialog.c
patch
|
blob
|
history
diff --git
a/gtk/gtkdialog.c
b/gtk/gtkdialog.c
index 73ae618322272c88a99e965cf94991f63569150c..bf41fb496d1a3ba108ef178afda9b9dd49170e88 100644
(file)
--- a/
gtk/gtkdialog.c
+++ b/
gtk/gtkdialog.c
@@
-793,6
+793,9
@@
gtk_dialog_map (GtkWidget *widget)
GtkWindow *window = GTK_WINDOW (widget);
GtkDialog *dialog = GTK_DIALOG (widget);
+ if (gtk_window_get_transient_for (window) == NULL)
+ g_warning ("GtkDialog mapped without a transient parent. This is discouraged.");
+
GTK_WIDGET_CLASS (gtk_dialog_parent_class)->map (widget);
focus = gtk_window_get_focus (window);